package com.qf.cx.simplenms.persist.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.qf.cx.simplenms.persist.dao.api.SwitchDao;
import com.qf.cx.simplenms.persist.entity.SwitchEntity;
import com.qf.cx.simplenms.persist.service.api.SwitchService;

@Service
@Transactional(value = "hibernateTransactionManager")
public class SwitchServiceImpl implements SwitchService {
	@Autowired
	private SwitchDao switchDao;

	@Override
	public void addSwitch(SwitchEntity switch0) {
		switchDao.addSwitch(switch0);
	}

	@Override
	public void deleteSwitch(SwitchEntity switch0) {
		switchDao.deleteSwitch(switch0);
	}

	@Override
	public SwitchEntity getOneSwitch() {
		return switchDao.getOneSwitch();
	}

	@Override
	public void deleteAll() {
		switchDao.deleteAll();
	}

}
